<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui"
	xmlns:ui="http://java.sun.com/jsf/facelets">

<h:head>
	<title>Crea Escursione</title>
	<link href="resources/css/main.css" rel="stylesheet" type="text/css" />
</h:head>
<h:body>
<header>
		<a><h:link class="logo" outcome="index" /></a>
	</header>
<div id="container">
		<div id="content1">
		<div id="contentLarge">
		<h:form>
		<p:panel header="Crea Escursione Form">
			<h:panelGrid columns="3" id="creaEscursioneGrid">
			
				<h:outputLabel for="nome">Nome:</h:outputLabel>
				<p:inputText id="nome" value="#{beanProdottoBase.edto.nome}" />
				<p:message for="nome" />
				
				<h:outputLabel for="oraDurata">Durata(ore):</h:outputLabel>
				<p:inputText id="oraDurata" value="#{beanProdottoBase.edto.oreDurata}" />
				<p:message for="oraDurata" />
						
				<h:outputLabel for="minutiDurata">Durata(minuti):</h:outputLabel>
				<p:inputText id="minutiDurata" value="#{beanProdottoBase.edto.minutiDurata}" />
				<p:message for="minutiDurata" />

				<h:outputLabel for="luogoPartenza">Luogo Partenza:</h:outputLabel>
				<p:inputText id="luogoPartenza" value="#{beanProdottoBase.edto.luogoPartenza}" />
				<p:message for="luogoPartenza" />

				<h:outputLabel for="prezzo">Prezzo:</h:outputLabel>
				<p:inputText id="prezzo" value="#{beanProdottoBase.edto.prezzo}" />
				<p:message for="prezzo" />

				<h:outputLabel for="stagione">Stagione:</h:outputLabel>
				<p:selectOneListbox id="stagione" value="#{beanProdottoBase.edto.stagione}">
				 	<f:selectItem itemLabel="Qualsiasi" itemValue="Qualsiasi" />  
           			<f:selectItem itemLabel="Inverno" itemValue="Inverno" />  
           		 	<f:selectItem itemLabel="Primavera" itemValue="Primavera" />  
           			<f:selectItem itemLabel="Estate" itemValue="Estate" />
           			<f:selectItem itemLabel="Autunno" itemValue="Autunno" />
      			</p:selectOneListbox> 
      			<p:message for="stagione" />
				
				<h:outputLabel for="tipologia">Tipologia:</h:outputLabel>
				<p:selectOneMenu id="tipologia" value="#{beanProdottoBase.edto.tipologia}">  
	            	<f:selectItem itemLabel="Seleziona" itemValue="" />  
	           		<f:selectItem itemLabel="Culturale" itemValue="Culturale" />  
	           		<f:selectItem itemLabel="Sportiva" itemValue="Sportiva" />  
	           		<f:selectItem itemLabel="Didattica" itemValue="Didattica" />
       			</p:selectOneMenu>
				<p:message for="tipologia" />

			</h:panelGrid>
			<p:commandButton value="Crea Escursione" update="creaEscursioneGrid"
				action="#{beanProdottoBase.saveEscursione()}" />

		</p:panel>
	</h:form>
        </div>
        </div>
        <a><h:link class="button1" outcome="creaProdottoBase" value="Indietro"/></a>
      </div>
 	<h:outputStylesheet library="css" name="main.css"/>
</h:body>
</html>